/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: YCKOKO
 * Date: 2022-11-03
 * Time: 23:43
 */
public class Test {
    public static void main(String[] args) {
        MyLinkedList myLinkedList1 = new MyLinkedList();
        myLinkedList1.addFirst(1);
        myLinkedList1.addFirst(2);
        myLinkedList1.addFirst(3);
        myLinkedList1.addFirst(4);
        myLinkedList1.display();
        System.out.println();
        System.out.println("===========");
        MyLinkedList myLinkedList2 = new MyLinkedList();
        myLinkedList2.addLast(1);
        myLinkedList2.addLast(2);
        myLinkedList2.addLast(3);
        myLinkedList2.addLast(4);
        myLinkedList2.display();
        System.out.println();
        System.out.println("===========");
        myLinkedList1.addIndex(0,10);
        myLinkedList1.display();
        System.out.println();
        myLinkedList1.addIndex(3,20);
        myLinkedList1.display();
        System.out.println();
        myLinkedList1.addIndex(6,10);
        myLinkedList1.display();
        System.out.println();
//        myLinkedList1.addIndex(8,10);
//        myLinkedList1.display();
//        System.out.println();
        System.out.println("===========");
        myLinkedList1.remove(2);
        myLinkedList1.display();
        System.out.println();
        myLinkedList1.remove(5);
        myLinkedList1.display();
        System.out.println();
        myLinkedList1.removeAllKey(10);
        myLinkedList1.display();
        System.out.println();
        System.out.println("===========");
        myLinkedList1.clear();
        myLinkedList1.display();
        System.out.println();
        System.out.println("===========");

    }
}
